#!usr/bin/env python
#coding=utf8

from django.core.urlresolvers import reverse

from former_project.business_logic.user import login_required
from former_project.web.render import render_to_response
from former_project.business_logic.common import viewcontrol

@login_required
def index(request):
    r_dic = {'base' : {}}
    r_dic['base']['test'] = reverse('formerapp-index')
    r_dic['test'] = 'hello world'
    r_dic['data'] = viewcontrol.get_hotnews_info('id',2)
    return render_to_response('common/index.html', r_dic, request)
